package cn.yanghan.org.mapper;

import cn.yanghan.org.domain.Department;
import cn.yanghan.org.query.DepartmentQuery;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface DepartmentMapper {
    //基础查询
    void save(Department department);

    void delete(Long id);

    void update(Department department);

    Department loadById(Long id);

    List<Department> loadAll();


    Long queryCount(DepartmentQuery query);
    List<Department> queryData(DepartmentQuery query);

    //批量删除
    void patchDel(Long[] ids);

    List<Department> loadDeptTree();
}
